import java.util.Scanner;

public class A3{
	public static void main(String[] agrs){
		Scanner sc = new Scanner(System.in);
		System.out.println("请输入第一个数");
		int a = sc.nextInt();
		System.out.println("请输入第二个数");
		int b = sc.nextInt();
		System.out.println("请输入第三个数");
		int c = sc.nextInt();
		int temp = a > b ? a : b;
		int result = temp > c ? temp : c;
		System.out.println("最大值是:" + result);
		
		// 再讲 &和|
		int d = 200;
		int e = 10;
		System.out.println(d & e);//8
		System.out.println(d | e);//202
		
		//switch的第 1 种写法
		int number = 1;
		switch (number){
			case 1:
			System.out.println("一");//一
			break;
		    case 2:
			System.out.println("二");
			break;
			case 3:
			System.out.println("三");
			break;
			default:
			System.out.println("没有这种选择");
		}
		//switch的第 2 种写法
		int number1 = 1;
		switch (number1){
			case 1 ->{
				System.out.println("一");//一
			}
			case 2 ->{
				System.out.println("二");
			}
			case 3 ->{
				System.out.println("三");
			}
			default ->{
				System.out.println("没有这种选择");
			}
		}
		//关于第二种写法,当case里面只有一句话时,可以省略括号
		int number2 = 1;
		switch (number2){
			case 1 -> System.out.println("一");//一
			case 2 -> System.out.println("二");
			case 3 -> System.out.println("三");
			default -> System.out.println("没有这种选择");
		}
		//就按盘录入星期数,输出工作日和休息日.(1-5)工作日,(6-7)休息日.
        int week = sc.nextInt();
        switch (week){
			case 1:
			case 2:
			case 3:
			case 4:
			case 5:
				System.out.println("工作日");
				break;
			case 6:
			case 7:
				System.out.println("休息日");
				break;
			default:
				System.out.println("没有这个星期");
				break;
		}		//另一种写法
		int week1 = sc.nextInt();
		switch(week1){
			case 1,2,3,4,5:
				System.out.println("工作日");
				break;
			case 6,7:
				System.out.println("休息日");
				break;
			default:
				System.out.println("没有这个星期");
				break;
		}       //另一种写法
		int week2 = sc.nextInt();
		switch(week2){
			case 1,2,3,4,5 -> System.out.println("工作日");
			case 6,7 -> System.out.println("休息日");
			default -> System.out.println("没有这个星期");
		}
		
	}
}